
// Evol scripts.
// Authors:
//    Reid
// Description:
//    Blacksmith's assistant of Artis
// Variables:
//    ArtisQuests_Enora
// Values:
//    0    Default.
//    1    BlackSmith quest delivered.
//    2    Chelios Quest given.
//    3    Chelios Quest done.
//    4    BlackSmith gave the sword.

001-1,95,109,0	script	Chelios	NPC_CHELIOS,{

    function give_small_quest {
        speech 5,
            l("Her sword... I'm having some trouble finishing it."),
            l("You see, Enora asked me to do a black iron sword, unfortunately I ran out of the material needed, and..."),
            l("Only Don and the Merchant Guild have that kind of material in stock. It's called black iron."),
            l("It's better to deal with the Merchant Guild than the old man, Don has this ability to hammer down your enthusiasm in sparkling fury!"),
            l("If Enora wants her sword now, I need to ask for your help.");

        switch (select (l("Let's not keep her waiting."),
                        l("Not now.")))
        {
            case 1:
                break;
            case 2:
                speech 5,
                    l("I'll be here, come back when you're ready.");

                return;
        }

        speech 5,
            l("Thank you very much!"),
            l("Talk with Lloyd the banker in the Merchant Guild, it's a big building at the Northern part of Artis, atop the little hill.");

        setq ArtisQuests_Enora, 2;

        return;
    }

    function more_info {
        speech 5,
            l("It's the big building at Northern Artis, at the top of a small hill."),
            l("Take the east road that goes to the north and follow it until you are on top of the cliff."),
            l("That part of the town is called the gilded hill, and where the Merchant Guild has its headquarters."), //rich hill
            l("Lloyd still owes me, but beware of those money-grubbers, or they will sell your own teeth to you!");

        return;
    }

    function quest_completed {
        speech 5,
            l("Oh... Awesome!"),
            l("You were gone; I thought you let me down. Some black iron was given to me by Don... after I asked nearly ten times."),
            l("But thank you anyway! I can refund him now!"),
            l("Take the sword, and say hi to Enora for me!");

        setq ArtisQuests_Enora, 4;

        return;
    }

    function blacksmith_house{
        speech 5,
            l("Behind me? It's the Blacksmith house, the most renowned throughout Andorra."),
            l("There are two shops inside, they are independent from the Merchant Guild of Artis; now that I think about it, they are the only shops that are independent in Artis..."),
            l("...this might be because of Don, he is the master blacksmith of this place and a model to me!");

        return;
    }

    speech 4, l("Can I be of any help?");

    do
    {
        .@enora = getq (ArtisQuests_Enora);
        menuint rif (.@enora == 1, l("I came to retrieve a package for Enora.")), 1,
                rif (.@enora == 3, l("I have your black iron.")), 2,
                rif (.@enora >= 2, l("Where is the Merchant Guild?")), 3,
                l("What is this building?"), 4,
                menuaction(l("Quit")), 5;

        switch (@menuret)
        {
            case 1:
                give_small_quest;
                break;
            case 2:
                quest_completed;
                break;
            case 3:
                more_info;
                break;
            case 4:
                blacksmith_house;
                break;
            case 5:
                break;
        }
    } while (@menuret != 5);

    closedialog;
    goodbye;
    close;

OnInit:
    .sex = G_MALE;
    .distance = 3;
    end;
}

